function create_plot2(M, Delta, theta_range, fig_number)

[w, Delta] = initialize_params(M, Delta);
y1 = spat_response(w,Delta,degtorad(theta_range));
w = gen_a(M, Delta, deg2rad(12));
y2 = spat_response(w,Delta,degtorad(theta_range));
figure(fig_number)
plot(theta_range, y1, 'b')
hold on
plot(theta_range, y2, 'r')
%plot(theta_range, y1+y2, 'k')
title('spatial response for scanning w')
xlabel('angle [deg]')
legend(['M = ' int2str(M) ' Delta = ' int2str(Delta) ' aplha = 0'], ...
    ['M = ' int2str(M) ' Delta = ' int2str(Delta) ' aplha = 12'] )

end